import kefuApi from "@/api/declaration/mall/kefuApi"
import httpRequest from "@/config/axios/httpRequest"


// 客服会话 API
export const KeFuMessageApi = {
  // 发送客服消息
  sendKeFuMessage: async (data: any) => {
    return await httpRequest.post(kefuApi.SendKeFuMessage, data)
  },
  // 更新客服消息已读状态
  updateKeFuMessageReadStatus: async (conversationId: number) => {
    return await httpRequest.put(kefuApi.UpdateKeFuMessageReadStatus, { conversationId })
  },
  // 获得消息分页数据
  getKeFuMessagePage: async (params: any) => {
    return await httpRequest.get(kefuApi.GetKeFuMessagePage, { params })
  }
}
